FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"

SRC_URI_append = " file://rc.local"

do_install() {
        install -d ${D}${sysconfdir}/
        install -m 0755 ${WORKDIR}/qtdemo-init ${D}${sysconfdir}/qtdemo

        if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
            install -d ${D}${sysconfdir}
            install -m 0755 ${WORKDIR}/rc.local ${D}${sysconfdir}
        fi

}

inherit update-rc.d allarch systemd
